<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@include file="/jsp/commons/taglibs.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<jsp:include page="/jsp/commons/cssinclude.jsp"></jsp:include>
<jsp:include page="/jsp/commons/scriptinclude.jsp"></jsp:include>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>晶品科技信息管理系统-供应商管理</title>

</head>
<body>
	<jsp:include page="/jsp/commons/top.jsp"></jsp:include>
	<div class="mainbox">

		<div class="main_content">
			<%@include file="/jsp/commons/leftMenu.jsp"%>
			<div class="main_right">
				<div class="main_rightbox">
					<div class="ec_crumb_kc">
						<span><a class="icon_up" href="#">上一页</a><a
							class="icon_index" href="${ctx }">首页</a></span>当前位置：配置管理&nbsp;&gt;&nbsp;<em>供应商管理</em>
					</div>
				</div>
				<!--品牌基本信息 begin-->
				<div class="ty_border">
					<div class="ty_head">
						<span class="icon4"></span>供应商基本信息
					</div>
					<div class="sx_body">
						<form  action="${ctx}/provider/providerAction!editProvider.action"
							id="providerForm" method="post">
							<input type="hidden" id="hbActionType" value="${actionType}" />
							
							<input name="provider.id" type="hidden" id="providerId" value="${provider.id}" />
							
							<dl class="clearfix">
								<dt style="display: none;">供应商基本信息</dt>

								<dd>
									<label class="name">供应商名称：</label><span class="toname"><input
										name="provider.name" type="text" value="${provider.name}"
										id="providerName" title="searchfield" class="winput3" /></span>
									<div class="fl">
										<em id="providerNameTip"></em>
									</div>
								</dd>
								<dd>
									<label class="name">联系人：</label><span class="toname"><input
										name="provider.contactor" type="text" value="${provider.contactor}"
										id="providerContactor" title="searchfield" class="winput3" /></span>
									<div class="fl">
										<em id="providerCodeTip"></em>
									</div>
								</dd>
								<dd>
									<label class="name">电话：</label><span class="toname"><input
										name="provider.tel" type="text" value="${provider.tel}"
										id="providerTel" title="searchfield" class="winput3" /></span>
									<div class="fl">
										<em id="providerTypeTip"></em>
									</div>
								</dd>
								<dd>
									<label class="name">传真：</label><span class="toname"><input
										name="provider.fax" type="text" value="${provider.fax}"
										id="providerFax" title="searchfield" class="winput3" /></span>
									<div class="fl">
										<em id="providerValueTip"></em>
									</div>
								</dd>
								<dd>
									<label class="name">手机：</label><span class="toname"><input
										name="provider.phone" type="text" value="${provider.phone}"
										id="providerPhone" title="searchfield" class="winput3" /></span>
									<div class="fl">
										<em id="providerValueTip"></em>
									</div>
								</dd>
								<dd>
									<label class="name">联系地址：</label><span class="toname"><input
										name="provider.address" type="text" value="${provider.address}"
										id="providerAddress" title="searchfield" class="winput3" /></span>
									<div class="fl">
										<em id="providerValueTip"></em>
									</div>
								</dd>
								<dd>
									<label class="name">反货地址：</label><span class="toname"><input
										name="provider.repareAddress" type="text" value="${provider.repareAddress}"
										id="providerRepareAddress" title="searchfield" class="winput3" /></span>
									<div class="fl">
										<em id="providerValueTip"></em>
									</div>
								</dd>
								<dd>
									<label class="name">经营产品：</label><span class="toname"><input
										name="provider.bisiness" type="text" value="${provider.bisiness}"
										id="providerBusiness" title="searchfield" class="winput3" /></span>
									<div class="fl">
										<em id="providerValueTip"></em>
									</div>
								</dd>
								<dd>
									<label class="name">开户行：</label><span class="toname"><input
										name="provider.bank" type="text" value="${provider.bank}"
										id="providerBank" title="searchfield" class="winput3" /></span>
									<div class="fl">
										<em id="providerValueTip"></em>
									</div>
								</dd>
								<dd>
									<label class="name">银行账号：</label><span class="toname"><input
										name="provider.account" type="text" value="${provider.account}"
										id="providerAccount" title="searchfield" class="winput3" /></span>
									<div class="fl">
										<em id="providerValueTip"></em>
									</div>
								</dd>
								<dd>
									<label class="name">账号户名：</label><span class="toname"><input
										name="provider.accountName" type="text" value="${provider.accountName}"
										id="providerAccountName" title="searchfield" class="winput3" /></span>
									<div class="fl">
										<em id="providerValueTip"></em>
									</div>
								</dd>
								
							</dl>

							<div class="baocun">
								<button class="gybg saveBtn" id="btnSave" type="button">保存</button>
								<button class="gybg qxBtn" type="reset">取消</button>
							</div>
						</form>
						<div class="clear"></div>
					</div>
					<!--保存取消 begin-->

				</div>

			</div>
		</div>

	</div>

	<!-- JQ -->

	<script type="text/javascript">
		//根据状态为来决定是增加还是修改
        $("#btnSave").click(function(){
        	var strActionType=$("#hbActionType").val();
        	if(strActionType!=""){
        		if(strActionType==0){
        			//新增操作
        		    $("#providerForm").attr("action","${ctx}/provider/providerAction!addProvider.action");
        		     $("#providerForm").submit();
        		}else if(strActionType==1){
        			//修改操作
        			$("#providerForm").attr("action","${ctx}/provider/providerAction!editProvider.action");
        			$("#providerForm").submit();
        		}else if(strActionType==2){
        			//查看详情
        			$("#providerForm").attr("action","${ctx}/provider/providerAction!detailProvider.action");
        			$("#providerForm").submit();
        		}else{
        			alert("系统错误，请联系系统管理员！");
        		}
        	}else{
    			alert("系统错误，请联系系统管理员！");
    		}
        });
		$(".ctnGdpOptionPanel li").hover(function() {
			$(this).addClass("hover");
		}, function() {
			$(this).removeClass("hover");
		});
		$(".arrowname").click(function() {
			var domUl = $(this).parent().find(".ctnGdpOptionPanelMask");
			var domArrow = $(this).find("span.arrowdown");
			if (domArrow.hasClass("arrowUp")) {
				domArrow.removeClass("arrowUp");
				domUl.show();
			} else {
				domArrow.addClass("arrowUp");
				domUl.hide();
			}
		});
	</script>
</body>
</html>